You are here: Symbol Reference > Dew Namespace > Dew.Math Namespace > Classes > Matrix Structure > Matrix Methods > Matrix.Split Method
Dew Math for .NET
ContentsIndexHome
PreviousUpNext
Matrix.Split Method

Splits matrix in blocks.

Syntax
C#
Visual Basic
public void Split(int aRows, int aCols, [In] TMtx[] Dst);

Splits the calling matrix in blocks. Example: 

 

[ A B ] [ C D ]

where A,B,C,D are matrices of size 2x2 and the calling matrix is of size 4x4. ARows and ACols define the number of rows and columns of the block based matrix. The matrices passed in the dst array to be filled with values from the calling matrix, must already have matching size and complex properties to cover the calling matrix or an exception will be raised.

var A,B,C,D,E: Matrix; begin A.Size(2,2); B.Size(A); C.Size(A); D.Size(A); E.SetIt(4,4,False,[1,2,3,4 5,6,7,8 9,1,2,3 4,5,6,7]); E.Split(2,2,[A,B, C,D]); // A becomes: // [1,2, // 5,6] // B becomes: // [3,4, // 7,8] // C becomes: // [9,1, // 4,5] // D becomes: // [2,3, // 6,7] end;
Copyright (c) 1999-2024 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!